using System;
using System.Collections.Generic;
using System.Text;

namespace NBusiness.Query.SqlServer
{
    public class SqlIs : SqlBoolean
    {
        public bool Not
        {
            get { return (base.Operator == SqlBooleanOperator.IsNot); }
            set { Operator = (value ? SqlBooleanOperator.IsNot : SqlBooleanOperator.Is); }
        }

        public SqlIs()
            : base(SqlBooleanOperator.Is)
        { }
        public SqlIs(IEvaluatable left, IEvaluatable right)
            : this(left, right, false)
        { }
        public SqlIs(IEvaluatable left, IEvaluatable right, bool not)
            : base(left, (not ? SqlBooleanOperator.IsNot : SqlBooleanOperator.Is), right)
        { }
    }
}
